<?php

namespace Medicina\BackendBundle\Form;

use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilder;

class PersonaOcupaCargoType extends AbstractType {

    public function buildForm(FormBuilder $builder, array $options) {
        $builder
//                ->add('cargo')
                ->add('persona')
                ->add('renueva')
                ->add('fechaInicio', 'date', array(
                    'widget' => 'single_text',
                    'format' => 'dd/MM/yyyy',
                    'attr' => array('class' => 'date'),
                    'label' => "Fecha de Inicio"))
                ->add('fechaFin', 'date', array(
                    'widget' => 'single_text',
                    'format' => 'dd/MM/yyyy',
                    'attr' => array('class' => 'date'),
                    'label' => "Fecha de Fin"))
        ;
    }
 
    public function getName()
    {
        return 'PersonaOcupaCargoType';
    }

    public function getDefaultOptions(array $options){
        return array('data_class' => 'Medicina\KernelBundle\Entity\PersonaOcupaCargo');
    }

}
